home *** CD-ROM | disk | FTP | other *** search
/ HAM Radio 3.2 / Ham Radio Version 3.2 (Chestnut CD-ROMs)(1993).ISO / packet / gil101 / gilmain.doc < prev    next >
Text File  |  1991-04-03  |  55KB  |  1,378 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.                                 GIL (c)
  17.  
  18.                         GRAPHICS INTERCHANGE LANGUAGE
  19.                              Version 1.01
  20.  
  21.                            A Public Domain Program
  22.  
  23.                       Copyright 1991 by Glenn L. Williams
  24.  
  25.                      Protected by Federal Copyright Law.
  26.  
  27.          Permission granted for non-commercial use and distribution.
  28.         Not to be used for commercial advantage.  All rights reserved.
  29.  
  30.  
  31.  
  32.                        This document contains (TBD) pages.
  33.  
  34.                        This is a draft copy for the beta release.
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.                        IBM(TM), AT&T(TM), Olivetti(TM), Hercules(TM),
  48.                        are trademarks of those well-known companies
  49.                        International Business Machines, American Telephone
  50.                        and Telegraph, Olivetti of Italy, and Hercules Corp.
  51.                        If other trademarks accidentally were omitted from 
  52.                        this list I apologize.
  53.  
  54. Disclaimer
  55. ----------
  56.  
  57. The author shall have no liability or responsibility to user or any other
  58. person or entity with respect to any loss or damage caused or alleged to be
  59. caused directly or indirectly through the use of this documentation or the GIL
  60. program.
  61.  
  62.  
  63. Distribution and Use of GIL
  64. -------------------------
  65.  
  66. GIL is a copyrighted program.  All rights are retained by the author. GIL is
  67. not to be sold; nor is it to be used for commercial purposes.  You may freely
  68. distribute GIL, and you are encouraged to do so, but you may not charge for
  69. doing so, except as permitted below.  The following files should be 
  70. included in any distribution:
  71.  
  72.  
  73.                                  GIL.EXE
  74.                                  GIL.DOC
  75.                                  GILMAIN.DOC
  76.                                  PENG.GIL
  77.                                  QSL.GIL
  78.                                  
  79. GIL is hereby placed into the public domain, but cannot be used or sold with a
  80. product supplied by a profit making corporation.  GIL may be used by any
  81. amateur radio operator, in amateur radio (non-profit) operating environments,
  82. and also by any not-for-profit organization, or any government agency, as long
  83. as product is not mixed in or sold with any for sale product costing more than
  84. $5.00 U.S. dollars, except as noted in paragraphs below. I.e. this program may
  85. be included in its archived (zip or arc) format or unarchive format to support
  86. other shareware but all rights to this product are to be retained in the
  87. public domain and the author's copyrights remain intact.
  88.  
  89. This product and its documentation in archived format may be uploaded to
  90. public domain bulletin boards, except no license is granted hereby for any
  91. commercial use or copyright transfer to any bill-for-service data base or
  92. bulletin board service, including, among others, BIX(TM), PRODIGY(TM),
  93. and COMPUSERVE(TM).
  94.  
  95. This utility is being provided free of charge for the main benefit of amateur
  96. radio operators worldwide. In the U.S.A. amateur radio is a hobby that is
  97. infinitely enjoyable for young and old.  We "hams" cannot receive a profit
  98. from anything we do in amateur radio, therefore, this program is freely
  99. available and the author expects no profit from it.  For this reason, this
  100. program and the .GIL file technique are NEVER to be used as a source of income
  101. by any individual or corporation.  The copyrights are not transferable. 
  102. However, this software may be sold on floppy disk by vendors of freeware and
  103. shareware where the floppy disks are sold for no more than $5.00 each via mail
  104. order or at fleamarkets and hamfests.
  105.  
  106.  
  107. 1. Purpose
  108. ----------
  109.  
  110. The primary purpose behind GIL is to permit a convenient way for radio 
  111. amateurs to send more than just plain ASCII text messages over the packet or
  112. RTTY radio links.   Before GIL, there was no convenient way to transmit over
  113. the radio, or via bulletin board, reasonably small "files" containing enough
  114. information to reconstruct a good line drawing or cartoon, over the radio.
  115.  
  116. 2. Starting GIL
  117. --------------------
  118.  
  119. If you have not already done so, please make a working copy of all GIL 
  120. disk files and store away the disk on which you received GIL for safekeeping,
  121. and use the working copy when you want to run GIL.  You may write protect
  122. the working copy because GIL will not usually write to the disk. (This applies
  123. to version 1.01 only. In the future releases the usage of the disk may change.)
  124.  
  125.  
  126. Your working disk should contain the following files:
  127.  
  128.           GIL.EXE   (The GIL executable program)
  129.  
  130. and several other  .GIL format files for your enjoyment.
  131.  
  132. Anyone wishing to send interesting new .GIL format files to the author
  133. would be highly appreciated. Also, new .GIL format files should be
  134. exchanged on packet and telephone bulletin boards!!
  135.  
  136.  
  137. 2.1  Interactive startup
  138. ------------------------
  139.  
  140. To run GIL in interactive mode, the following command syntax is used:
  141.  
  142. Start from your DOS prompt with the command:
  143.  
  144.     GIL
  145.  
  146. and when you receive the "GIL>" prompt, then type in ASCII commands that will
  147. be further described below . As each command is typed it will be listed on the
  148. screen, and then executed when you type the ENTER key.  Just above the command
  149. line your most recent command is listed, and just below the command line (in
  150. some cases) are error messages. When you are done and wish to go back to DOS,
  151. use the ".bye" command to exit.
  152.  
  153. Ultimately you may want to compose .GIL files with a text editor or word
  154. processor and then "batch" process them through the program. Further
  155. instructions below will describe the process in detail.
  156.  
  157.  
  158. 2.2  Non-interactive startup "BATCH MODE"
  159. ---------------------------- ------------
  160.  
  161. For straight ASCII file input mode, GIL accepts input from "stdin" redirection,
  162. as follows:
  163.  
  164.     GIL  <[drive:][path][filename]
  165.          ^
  166.          |......note this "<" character used for stdin input redirection.
  167.  
  168. At the end of the drawing process, when you are done viewing the drawing,
  169. striking any key will clear the screen and return you to DOS.
  170.  
  171. Anyone not familiar with "stdin" redirection should consult the operation
  172. of the DOS COMMAND.COM shell in his DOS manual.
  173.  
  174. Therefore, just for the sake of getting some idea of what GIL can do, try
  175. the following command  (VGA or EGA recommended):
  176.  
  177.    GIL <OPUS.GIL
  178.  
  179. If you are an amateur radio operator, or if you have only a monochrome
  180. Hercules Graphics Adapter, try:
  181.  
  182.    GIL <QSL.GIL
  183.  
  184. If you have a TSR utility such as GRAPHICS.COM (usually supplied with your
  185. DOS for CGA adapters), or EGAPRTSC.COM (for EGA adapters)  you can also print
  186. the screen to an IBM or EPSON dot matrix printer, for obtaining a hard copy. 
  187. That is, any TSR screen capture utility or printer utility capable of can
  188. "grab" the screen and "live" as a TSR (Terminate and Stay Resident) utility in
  189. your computer, can print the screen. However, at this time, the author has not
  190. had the time and resources to test all the TSRs's out there for compatibility
  191. with GIL. Nor is it expected at this time for GIL to cooperate with Microsoft
  192. Windows (TM) in any way other than as a "DOS" program. But since GIL interacts
  193. with your video card, it may or may not have a deleterious effect when
  194. operated under programs that use screen graphics as part of a "windows" or
  195. "shell" environment.
  196.  
  197. WARNING: GIL will interact with your screen graphics adapter. As a result
  198. it will "trash" anything else on the screen.  GIL has not been tested with
  199. all the graphics adapters in the world, and especially not with the monochrome
  200. versions of CGA, EGA, and VGA.  The graphics routines are supported via the
  201. Microsoft Corporation "C" library for Quick-C 2.5 (TM) and any artifacts
  202. created by the standard library are not the fault of this author.
  203.  
  204. NOTE:  No compatibility with Microsoft Windows (TM) is implied in any way. 
  205. Since GIL interacts with your video card, it may or may not have a deleterious
  206. effect when operated under programs that use screen graphics as part of a
  207. "windows" or "shell" environment.
  208.  
  209.  
  210. 2.2.1 BATCH MODE AND PIPING UNDER DOS
  211. -------------------------------------
  212.  
  213. The GIL program accepts input from either your command line inputs that
  214. you type in, or from "stdin"  (standard input) using the redirection
  215. symbol "<".  The latter permits GIL to accept "piped" input that is 
  216. generated as the output of other programs.  This piped input is very
  217. useful in batch (.BAT) files for displaying neutral files created by
  218. other DOS programs.  (This opens up the possibility of "GIL extender"
  219. programs that create .GIL format neutral file output from sophisticated
  220. user interfaces!)
  221.  
  222. For example, the DOS batch file below assumes that a program MAKER.COM
  223. creates a list of GIL commands. The list can be piped into GIL:
  224.  
  225. COPY A:OLDDATA.DAT NEWDATA.DAT
  226. MAKER NEWDATA.DAT >GIL.OUT
  227. TYPE GIL.OUT | GIL
  228.  
  229. With this example, MAKER operates on NEWDATA.DAT and by some magic process
  230. generates output (to "stdout") which is redirected to the file GIL.OUT (just
  231. so the GIL commands can be viewed later in case of a need to debug something).
  232. GIL.OUT is then "piped into" GIL.
  233.  
  234. There is a real example of a need for this.  For example, you receive via
  235. packet radio or telephone BBS a file with a really interesting drawing. But
  236. you want to try stretching the drawing in the Y axis direction on your
  237. screen.  The file STRETCH.BAT can take care of it WITHOUT modifying the
  238. original .GIL data file.
  239.  
  240. type aspect.gil >temp.gil
  241. type qsl.gil >>temp.gil
  242. type temp.gil |gilmain
  243.  
  244. where the contents of aspect.gil is the single ASCII line:
  245.  
  246. .aspect .5
  247.  
  248. In this example, the first stdout redirection in STRETCH.BAT creates the
  249. file TEMP.GIL.   In the next line, QSL.GIL is appended to the end of the
  250. file TEMP.GIL with the ">>" syntax for append to file. Then TEMP.GIL
  251. is type-ed to stdout which is piped into GIL with the "|" syntax.
  252.  
  253.  
  254. SOAPBOX: users not aware of the utility of "stdin", "stdout", and piping,
  255. are missing some very useful features of DOS.
  256.  
  257.  
  258.  
  259. 3.0  Neutral format "GIL" files
  260. -------------------------------
  261.  
  262. Since they are ASCII files, the .GIL type neutral files can be exchanged,
  263. sent to PBBS systems, E-Mailed, etc. to other users.  Once the user has a copy
  264. of GIL.EXE, he/she can view the "drawings" and obtain hardcopies as described
  265. below.
  266.  
  267. It is the author's original intended purpose for amateur radio operators to
  268. freely exchange copies of GIL.EXE and any associated .GIL type neutral files.
  269. GIL.EXE should be exchanged via telephone modem or floppy disk ("Nike Net")
  270. exchange.
  271.  
  272. The ASCII .GIL type neutral files are intended for exchange via packet radio
  273. worldwide.  These files carry the information for making a drawing, but being
  274. ASCII, they contain no information of an encrypted nature which would violate
  275. national or international regulations about exchanging encrypted information
  276. via amateur radio.  Since these files are (usually) short, they will not "hog"
  277. precious radio bandwidth.
  278.  
  279. IMPORTANT NOTE:  when using a word processor, the user should be sure to
  280. save the final output as unformatted ASCII text output, without any of the
  281. special formatting usually supplied by a saved word processor file.  That is,
  282. if you can view the final results with EDLIN or TYPE, then you are ready
  283. to submit the file data to GIL.
  284.  
  285. WORDSTAR(TM), WORD(TM), WORDPERFECT(TM), FIRST PUBLISHER(TM), EXPRESS 
  286. PUBLISHER(TM) and other document processing programs usually create
  287. other than "generic ASCII" file output. These files will cause great
  288. confusion if used with GIL while containing embedded word processor
  289. commands.
  290.  
  291.  
  292. 3.1  Use with Amateur Packet Radio and RTTY
  293. ---  --------------------------------------
  294.  
  295. Since they are ASCII files, the .GIL type neutral files can be exchanged,
  296. sent to PBBS systems, E-Mailed, etc. to other users.  Once the user has
  297. a copy of GIL.EXE, he/she can view the "drawings" and obtain hardcopies as 
  298. described below.
  299.  
  300. As described elsewhere, GIL accepts ASCII input in a "neutral" file
  301. format.  It does NOT contain a "terminal emulator" mode in this release.
  302. Therefore, for use with amateur radio files, the data will have to be
  303. first downloaded and stored on disk from a radio or land line source.
  304. Next, since most sources of data will contain other ASCII protocols and
  305. "overhead" necessary for BBS operation, the files should be previewed first
  306. with a text editor or word processor to clean out the portions that GIL
  307. will treat as "garbage".
  308.  
  309.  
  310. 3.2  BRIEF INTRODUCTION OF THE SCREEN LAYOUT
  311. --------------------------------------------
  312.  
  313. DEFINITION OF VIEWPORT COORDINATES
  314. ----------------------------------
  315.  
  316. Once the program start up and establishes the type of graphics controller
  317. in use, it sets up some default colors and then issues a prompt line at the
  318. lower left part of the screen.  This will be described in more detail below.
  319.  
  320. Above the two text lines used for prompting, the rest of the screen
  321. should be blank.  Actually, this is the graphical drawing area for the
  322. screen, called the viewport.  Althought the different graphics controllers
  323. have different pixel dimensions in X and Y on the screen, the viewport
  324. coordinates are adjusted so YOU the user only use viewport coordinates,
  325. with the exception of the .text command which uses 22 rows of alphanumeric
  326. characters.
  327.  
  328. The horizontal (X) dimension of the viewport is 1000.  The correct pixel values
  329. run from 1 to 1000.  However, via a technique called "clipping", all values
  330. that exceed the size of the viewport are treated as if valid, but the only
  331. lines and graphics that are drawn are the parts that fit inside ("are clipped
  332. off to fit inside") the viewport.
  333.  
  334. The vertical (Y) dimension of the viewport is nominally at least 500. The
  335. exact value used depends on the type of graphics controller and the aspect
  336. ratio established by  the .aspect command described in the Reference.
  337. This is somewhat cut and try due to the variability in graphics adapters.
  338.  
  339. Viewport coordinates start from the top left corner of the screen
  340. (at a point called "1,1") and run to the lower right hand corner of the
  341. screen (at a point "1000,540") where "540" is merely the nominal height
  342. of the viewport as described above.   Therefore, all drawing commands
  343. use viewport coordinates, NOT screen locations.  (But all text commands
  344. use screen coordinates!  -- The reason for this inconsistency is described
  345. elsewhere.)
  346.  
  347.  
  348.  
  349. 3.3 HOW TO MAKE A DRAWING
  350. -------------------------
  351.  
  352. If you have some idea of what you want to do, you can just enter GIL
  353. interactively and test your commands on the screen to see what happens. Keep a
  354. list of what they do, and later you can type them into a file with a text
  355. editor (NOT necessarily a WORD PROCESSOR!) and then execute them in batch mode.
  356.  
  357. Another way, especially good for use with existing drawings or new very
  358. complicated drawings, is to use lined paper or semi-transparent graph paper,
  359. ruled off and marked for use with GIL by showing the scale in viewpoint
  360. coordinates.  For example, holding a sheet of paper in landscape orientation,
  361. with the long axis horizontal, mark off a large box 10 units (inches, or 20
  362. mm) across and about 6 or 7 units high.  With some graph paper, such as
  363. KEUFFEL AND ESSER(TM) graph sheets, with fine rulings (10 to the inch, every
  364. millimeter, etc.) you can set up a reasonably tight scale with good precision.
  365. Number the Y axis DOWN from the top and the X axis across from left to right. 
  366. Then lay this graph paper over the object to be traced, or just sketch the
  367. object. In the case of a large scale mismatch, take your original drawing to a
  368. photocopy center with copiers with magnify/zoom capability and make a copy that
  369. is approximately the size you need for the graph paper.
  370.  
  371. With the drawing transferred to the graph paper, you can then compose the
  372. commands for GIL.
  373.  
  374. APOLOGY
  375. -------
  376.  
  377. Upon initial trial, some people may view this method of forced entry of
  378. awkward neutral file commands into the program as being rather clumsy and
  379. tedious.  However, the resulting files are ASCII files with a very high degree
  380. of data compression already built in.  This feature, and the fact that the
  381. data is editable by anyone on a PC with a text editor or word processor,
  382. results in relatively small files. Such files are suitable for transmission to
  383. amateur radio and telephone oriented bulletin board systems without the
  384. complications of data encryption or having to purchase expensive software
  385. graphics utilities.
  386.  
  387. 3.4 VIDEO GRAPHICS CARD COMPATIBILITY
  388. -------------------------------------
  389.  
  390. This program was written for and compiled with Microsoft Quick-C (TM) V.2.5.
  391. For the remainder of this document, the compiler will just be called "C".
  392. Microsoft C functions for controlling video graphics were found to excecute
  393. faster then at least one other product on the market, and in addition, the
  394. support of the Hercules Graphics Card was found to be a definite boon. The
  395. program was written using the support of these functions, and therefore certain
  396. requirements of those functions also constrain the operation of the program.
  397.  
  398. This program supports VGA, EGA, CGA, and HGC graphics controllers. In the
  399. attempt to provide a Graphics Interchange Language that spans the breadth
  400. of the differences between these graphics controllers, the user will have
  401. to be aware of some compromises:
  402.  
  403.       HGC (Hercules) - supports only monochrome video in 720 x 348 format
  404.  
  405.       CGA (Color Graphics Adapter) - supports only 4 colors, in low
  406.           density 320 x 200 pixel format.
  407.  
  408.       EGA (Enhanced Graphics Adapter) - supports only 16 colors, in
  409.           a higher density pixel format of 640 x 200.
  410.  
  411.       VGA (Video Graphics Adapter) - supports either 256 colors or 16
  412.           colors, in a 640 x 480 format.
  413.  
  414. In addition, the C library used with the compiler also supports the 
  415. AT&T Olivetti  variants, known as "OVGA", "OEGA", and "OCGA". It also
  416. supports the MCGA adapter defined by IBM.  Therefore support for these
  417. adapters has been included by intent, at least. But these remain untested.
  418.  
  419. To achieve some compatibility between these graphics adapters, the usage
  420. of color in .GIL neutral files will result in certain problems for users
  421. restricted to CGA or HGC adapters. As a result, the program makes the following 
  422. color choices and display choices.
  423.  
  424.  
  425. DISPLAY AREA
  426. ------------
  427.  
  428. All adapters are assumed to have no more than 320 horizontal rows of
  429. pixels.  This establishes a constraint that keeps VGA displays from
  430. overwriting the command line, and keeps the format basically compatible
  431. with HGC.
  432.  
  433.  
  434. SCREEN COLORS
  435. -------------
  436.  
  437.                      COLORS SUPPORTED
  438.                      ----------------
  439.  
  440.  
  441. SPELLING             HGC    CGA    EGA    VGA
  442.  
  443. BLACK         0      x      x(0)   x      x
  444. BLUE          1                    x      x
  445. GREEN         2                    x      x
  446. CYAN          3                    x      x
  447. RED           4                    x      x
  448. MAGENTA       5                    x      x
  449. BROWN         6                    x      x
  450. LTGRAY        7                    x      x
  451. DKGRAY        8                    x      x
  452. LTBLUE        9                    x      x
  453. LTGREEN      10             x(2)   x      x
  454. LTCYAN       11                    x      x
  455. LTRED        12             x(1)   x      x
  456. LTMAGENTA    13                    x      x
  457. YELLOW       14                    x      x
  458. WHITE        15      x      x(3)   x      x
  459.  
  460.        NOTE:  For HGC, all colors other than BLACK are forced to WHITE
  461.  
  462.               For CGA, color indexes not marked with "x" are right-shifted
  463.               by two bits. I.e. "DKGRAY" which equals 8 (decimal) will become
  464.               color index 2, which will appear as LTGREEN. LTMAGENTA (13) will
  465.               become 3 (WHITE), etc.  However, BLACK, LTGREEN, LTRED, and WHITE
  466.               will work well with CGA.
  467.  
  468. Therefore, if a drawing is to be presented to all users in an equal manner,
  469. obviously only BLACK and WHITE are useful, and for the most part any filled
  470. shapes should be kept as simple as possible.  In some cases color can be
  471. used, but only if the intent is such that either monochrome just will not
  472. do, or when unexpected change of color also will not be serious.
  473.  
  474. As will be described below, the ".require" command can be used to constrain
  475. operation of .GIL files with a particular adapter format.  However, the
  476. ".require" commands can also be edited out in order to "try out" the files
  477. in case of curiousity.
  478.  
  479.  
  480. 3.5 COMPUTER COMPATIBILITY  ISSUES
  481. ----------------------------------
  482.  
  483. By definition GIL will use the graphics screen of your PC-style computer.
  484. GIL will attempt to remember your default video modes and colors when it
  485. executes, so that upon exiting back to DOS, GIL will clean up and reset
  486. back to your defaults. But while GIL is executing, colors and modes
  487. may be changed.
  488.  
  489. Every attempt has been made to make emergency termination of the program
  490. possible whenever certain error conditions occur:
  491.  
  492.       CTRL-C typed
  493.       CTRL-BREAK typed
  494.       Floating Point Error occurs   (bugs, what bugs???)
  495.       Other abnormal conditions
  496.  
  497. When these actions occur, just before returning to DOS the program also
  498. attempts to restore your screen back to the condition in which it was found
  499. when GIL was invoked.  However, there are no guarantees that this will always
  500. be possible. Attempting to exit GIL with a BREAK or CTRL-C keystroke may under
  501. some circumstances result in your video adapter being left in other than your
  502. default operating state.  Conditions that may make normal termination
  503. impossible could possibly be caused by "other" Terminate and Stay Resident
  504. (TSR) programs residing in memory.  "Other" programs include the wrong
  505. MSHERC.COM (in the case of your running a Hercules Graphics Adapter), or
  506. something other than the suggested print screen TSRs (GRAPHICS.COM,
  507. HPGRAPH.COM, EGAPRTSCRN, etc.).
  508.  
  509. At present GIL does not make use of either the COM or LPT ports of the
  510. computer, nor does it write to disk.  GIL requires DOS 3.3 or above,
  511. and will run in less than 512K of memory. GIL should not care whether
  512. it is executed from floppy or hard disk, since it assumes nothing but
  513. standard DOX path arguments for seeking files or data.
  514.  
  515. GIL will also make use of the speaker device as a useful adjunct to
  516. screen graphics.  Again, the same conditions apply as above, regarding
  517. aborting the program with "other" TSRs in memory. Under these conditions
  518. aborting GIL with BREAK or CTRL-C might leave your speaker "ON" with a tone 
  519. running.  If this happens, restart GIL interactively, and then ".bye" out 
  520. of it, or issue a short .beep command.  In the extremely unlikely case
  521. that the the problem now continues, then you will have to reboot your 
  522. computer.
  523.  
  524. In your CONFIG.SYS file, be sure to enable the ANSI.SYS device driver.
  525.  
  526. GIL does NOT require a co-processor. (A later release may permit faster
  527. graphics using the co-processor.)
  528.  
  529. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  530.  
  531.  
  532.  
  533.                         GIL (c)  1.01
  534.  
  535.  
  536.                       COMMAND REFERENCE
  537.                       -----------------
  538.  
  539.  
  540.  
  541. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  542.  
  543.  
  544. GENERAL NOTES ON COMMANDS:
  545. --------------------------
  546.  
  547. A command is given to GIL as only one type of entry.
  548.  
  549. 1.)  A GIL executable command starts with the period, or dot, "."
  550.  
  551. 2.)  A "comment" is any ASCII text entered where the first character
  552.      in the first column is the "#" character. Comments will be
  553.      ignored.
  554.  
  555. 3.)  Empty lines consisting entirely of whitespace are ignored.
  556.  
  557. 4.)  Any other lines of ASCII text beginning with other than the "."
  558.      character will be treated as data or garbage, depending on the
  559.      context.
  560.  
  561.  
  562. SPECIAL CHARACTERS
  563. ------------------
  564.  
  565. The use of "#" and "." have just been described.
  566.  
  567.  
  568. UPPER CASE AND LOWER CASE
  569. -------------------------
  570.  
  571.  
  572. Commands can be either UPPER or LOWER case.  In some commands requiring
  573. alphanumeric, non-numeric, data, such as the  ".color" command for color
  574. specification, the alpha may be in UPPER or LOWER case also.  The only
  575. case sensitive input is the data you specify for the text to be displayed
  576. in the ".text" command.
  577.  
  578.  
  579. ERROR MESSAGES
  580. --------------
  581.  
  582. In certain isolated cases when bad data or commands are entered, a
  583. two-tone beep will occur to signal the user that display is otherwise
  584. impossible.
  585.  
  586. For example, it is possible for the color parameter of the hue command
  587. (such as BLACK) to cause display of the "GIL>" prompt to be in the same
  588. color as the background color (entered with the ".backdrop" command).
  589. After that, the user may get flustered and enter a new ".color" command
  590. with a misspelled color parameter. Since the error message cannot
  591. be displayed (it is also lost in the background color at this point) a
  592. two-tone beep is one way to indicate an error message.
  593.  
  594. If bad command syntax occurs, error messages will be displayed on the
  595. screen.
  596.  
  597. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  598.  
  599.  
  600. GENERAL COMMAND STRUCTURE
  601. -------------------------
  602.  
  603. Most commands consist of the leading "." in column one, followed
  604. by the command name, with no intervening spaces, and then a series
  605. of numerical or text parameters.  Except for extended commands,
  606. the command entry is concluded by typing the ENTER key. Therefore
  607. most command lines will be shorter than 80 columns. In fact, the
  608. program assumes a default maximum of 80 columns per ASCII line
  609. (40 for CGA).
  610.  
  611. After the command keyword, parameters are entered.  Commands
  612. and parameters can be separated by "white space", e.g. SPACE,
  613. TAB, and/or also by the COMMA.  This should allow "easy" formatting
  614. of data by programs used to "assist" in generating polygons, lines,
  615. etc.
  616.  
  617. Therefore, the following command structure exists for most of the
  618. commands:
  619.  
  620.    .command n1 n2 n3 n4 ... nk
  621.  
  622. where "command" is the keyword, and n1 through nk are numerical
  623. or alphanumerical parameters. For the detailed command descriptions
  624. below, this structure is important to understand now.
  625.  
  626. A few commands, such as .polygon and .wave, require something 
  627. in addition:
  628.  
  629.  
  630. EXTENDED COMMANDS
  631. -----------------
  632.  
  633. Some commands, such as ".polygon" and ".wave", will require so much data that
  634. more than one line of data can be entered to fulfill the list.  The lines of
  635. data coming after such a command line will
  636.  
  637.   (a) always be numeric, and 
  638.   (b) must be terminated with the final ".end" command.
  639.  
  640.  
  641. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  642.  
  643.  
  644. # comment lines
  645. ---------------
  646.  
  647. With a # as the first character in the line, ALL of the remaining line
  648. is disregarded.  However, it is a useful way to place information in the
  649. file for debugging and explanation purposes.
  650.  
  651.  
  652. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  653.  
  654. .arc3 n1 n2 n3 n4 n5 n6
  655. ----- -- -- -- -- -- --
  656.  
  657.  
  658. Description     This routine is based on the geometrical rule that a circle
  659.                 can be drawn through any three points on the plane, thus the
  660.                 name "arc" (draw an arc) concatinated with "3" (three points
  661.                 determine the circle).
  662.  
  663.                 In this program the arc is drawn COUNTER-CLOCKWISE from the 
  664.                 first set of viewpoint coordinates (n1, n2) to the third set
  665.                 of viewpoint coordinates (n5, n6).  The important effects are
  666.                 caused by the second set of coordinates, (n3, n4), which
  667.                 determine the "bending" necessary to make the circle. NOTE:
  668.                 after the circle is calculated, the only part displayed is
  669.                 the part obeying the above rule.  If the bending point is
  670.                 in the portion of the circle that would require drawing
  671.                 clockwise from (n1, n2) to (n5, n6) it will not actually
  672.                 be part of the arc. Rather it will be part of the gap.
  673.  
  674.                 A problem can occur under certain conditions when the end
  675.                 points of the arc or the bending point fall on coordinates
  676.                 which cause division by zero.  This can occur for instance
  677.                 when n1 = n5 or n2 = n6.  There are other combinations that
  678.                 cause this also.  Also, if the three points lie in a line, 
  679.                 there is no way to determine if the arc is concave or convex.
  680.                 This program will examine the entered coordinates, and in 
  681.                 certain cases "dither" the coordinates by adding in a small 
  682.                 amount of random noise that is less than +/- 1.0 (width of 
  683.                 one pixel in floating point). The net effect should amount
  684.                 to an indistinguishable error in the size of the arc.
  685.  
  686.                 The default or most recent drawing color is used for this curve.
  687.  
  688. Remarks        Clipping at the edge of the viewport WILL occur for arcs
  689.                 drawn to be larger than the viewport. This can be used to 
  690.                 advantage (like say you want to draw an artificial horizon),
  691.                 or for zooming into a drawing. See description of clipping
  692.                 elsewhere.  If you want to draw the entire circle, then
  693.                 draw one arc as per above, and then enter a second command
  694.                 with the end points interchanged in the command line.
  695.  
  696. See Also    .color, .ellipse
  697.  
  698. Defaults:       n1 = 100, n2 = 100, n3 = 100, n4 = 100, n5 = 100, n6 = 100.
  699.                 Net effect: either nothing or a small dot is drawn, depending
  700.                 on the outcome of the random number routine.
  701.  
  702. Bugs        Aliasing on the edges of the arc is NOT removed.
  703.                 Very tiny circles will thus appear lumpy.
  704.  
  705. Example        .arc3 300 100 200 50 100 100
  706.                 To draw a full circle, the gap is filled in with
  707.                 .arc3 100 100 200 50 300 100
  708.  
  709. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  710.  
  711.  
  712.  
  713.  
  714. .aspect n1
  715. ------- --
  716.  
  717. Description    Used to correct for the differences in aspect ratio of 
  718.                 different displays or adapters, such as VGA or HGC.
  719.                 Also, .aspect can be used to "stretch" or "crunch" a
  720.                 display for making "square" printouts with print utilities.
  721.  
  722.                 The parameter n1 is a floating point number, usually in
  723.                 the range .7 to 1.5, used to expand or compress the vertical
  724.                 scale of the drawing for better looks on some displays.
  725.                 Numbers greater than 1.0 are expansions.
  726.  
  727.  
  728. Remarks
  729.  
  730. See Also        .require
  731.  
  732. Bugs            Any problems are caused by the attempt to be all things
  733.                 to all adapters.
  734.  
  735. Example        .aspect 1.3
  736.  
  737. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  738.  
  739.  
  740.  
  741.  
  742. .backdrop n1 
  743. --------- --
  744.  
  745. Description    Used to set/change the default color for the background color
  746.                 of the viewport. Lifetime of this command's effects last until
  747.                 the next .backdrop command.
  748.  
  749. Remarks         See previous pages for the color table used for the various
  750.                 graphics adapters. See also the notes on compatibility between
  751.                 adapters.
  752.  
  753. See Also        .color
  754.  
  755. Bugs            There are never enough colors.  There is no orange. The
  756.                 backdrop color affects the way these colors are displayed,
  757.                 in ways you can best judge by experimentation.
  758.  
  759. Example         .backdrop  , LTGRAY
  760.  
  761. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  762.  
  763.  
  764.  
  765.  
  766. .beep n1 
  767. ----- --
  768.  
  769. Description    Used to sound the speaker for the time duration n1.
  770.                 n1 is an unsigned decimal integer. Units of n1 are
  771.                 approximately tenths of a second.
  772.  
  773. Remarks        Use of large values for n1 will result in LONG waits
  774.                 and possible stares from other people around you.
  775.  
  776. See Also    .pitch
  777.  
  778. Bugs        See Remarks.  Can you wear out a speaker?  Under
  779.                 some conditions (see text) aborting with CTRL-C or
  780.                 CTRL-BREAK may leave the speaker permanently ON.
  781.                 This usually should not be a problem, however.
  782.  
  783. Example        .beep 10    gives a one second tone.
  784.  
  785. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  786.  
  787.  
  788.  
  789.  
  790. .box n1 n2 n3 n4  (open box)
  791. ---- -- -- -- --
  792.  
  793. .fbox n1 n2 n3 n4 (filled box)
  794. ----- -- -- -- --
  795.  
  796. Description    Used to draw a box, or rectangle, from coordinates of the 
  797.                 first point (n1,n2) to the coordinates of the second
  798.                 point (n3,n4).  Coordinates of both points are in viewport
  799.                 coordinates.
  800.  
  801. Remarks        The endpoints can lie outside the viewport. Active clipping
  802.                 will ensure that only the portion of the line inside the
  803.                 viewport will be shown.
  804.  
  805. See Also    .polygon, .color
  806.  
  807. Defaults:       n1 = 100, n2 = 100, n3 = 200, n4 = 200.
  808.  
  809. Bugs        Aliasing effects ("zaggies") are NOT eliminated by this
  810.                 program.
  811.  
  812. Example        .box 23 49 800 300
  813.  
  814. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  815.  
  816.  
  817.  
  818. .bye
  819. ----
  820.  
  821.  
  822.  
  823. Description    This command is used to exit GIL and return the screen
  824.                 to the default DOS display.
  825.  
  826. Remarks        This command is the recommended way to exit GIL while
  827.                 in interactive mode. Using CTRL-C or CTRL-BREAK is  
  828.                 possible, but not recommended and may result in confused 
  829.                 screen setup or confused screen colors or a continuous 
  830.                 speaker tone when DOS returns control, although these are 
  831.                 very remote possibilities.
  832.  
  833. See Also    
  834.  
  835. Bugs    
  836.  
  837. Example        .bye
  838.  
  839. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  840.  
  841.  
  842.  
  843.  
  844.  
  845. .cgatext n1
  846. -------- --
  847.  
  848. Description     This command is used to turn on a "fudge" factor for displaying
  849.                 non-CGA files on CGA adapters, when ".text" lines would normally
  850.                 call for characters in columns 41-80.  This command, when
  851.                 n1 = ON, will cause all text from .text commands to be shifted
  852.                 to the left, such that the column address called for will be
  853.                 divided by exactly 2, and rounded down if necessary. That is,
  854.                 if the command ".text 10 50 Hello" is given, the result on the
  855.                 screen will effectively be ".text 10 25 Hello".
  856.  
  857.                 Parameter n1 is not case sensitive and can be either:
  858.  
  859.                 n1 = ON   or  n1 = OFF
  860.                 
  861. Remarks            CGA screens are only half as wide (in pixels) as EGA, CGA, etc.
  862.                 Thus graphics, when scaled to fit CGA, will not line up with
  863.                 text, which is presently using row and columc text boundaries.
  864.                 In addition, CGA pixels are twice as large (huge) when compared
  865.                 to the other adapters, so even when text is placed only half as
  866.                 far across the screen, it will often be also too high when
  867.                 compared to the other adapters.
  868.  
  869. See Also    .text
  870.  
  871. Bugs        Therefore, per the remarks, the end result will only be close,
  872.                 but not exact, and often will still not yet be satifactory.
  873.                 Some incompatibilities between CGA and other adapters cannot
  874.                 be totally "fudged" away.
  875.  
  876. Example        .cgatext on
  877.  
  878. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  879.  
  880.  
  881.  
  882.  
  883. .circle n1 n2 n3    (line circle)
  884. ------- -- -- --
  885.  
  886. .fcircle n1 n2 n3   (filled circle)
  887. -------- -- -- --
  888.  
  889. Description    Used to draw a circle in the viewport. The center of the
  890.                 circle is at x = n1, y = n2. The radius is n3.  The default
  891.                 color is used for both the lined form and the filled disc
  892.                 form.
  893.  
  894. Remarks        Clipping at the edge of the viewport WILL occur for circles 
  895.                 drawn to be larger than the viewport. This can be used to 
  896.                 advantage (like say you want to draw an artificial horizon),
  897.                 or for zooming into a drawing. See description of clipping
  898.                 elsewhere.
  899.  
  900. See Also    .color, .ellipse
  901.  
  902. Defaults        The center is n1 = 150, n2 = 150, with a radius of
  903.                 n3 = 100.
  904.  
  905. Bugs        Aliasing on the edges of the circle is NOT removed.
  906.                 Very tiny circles will thus appear lumpy.
  907.  
  908. Example        .circle 250 283 100
  909.  
  910. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  911.  
  912.  
  913. .color n1
  914. ------ --
  915.  
  916. Description    Used to set/change the default color for all drawing
  917.                 and filling operations that follow, until the next occurrence
  918.                 of a .color command.  Note that only one parameter is
  919.                 accepted, and it must be a color per the table above, not
  920.                 a numeric value. The lifetime of this color is until the
  921.                 next .color command.  This color ALSO affects the color
  922.                 of the text and command line displays, as well as error
  923.                 messages.  It is not a good idea to make this color the
  924.                 same as the backdrop color. EXCEPTION: if you want to
  925.                 print the screen, making this color the same as the back-
  926.                 drop color will "hide" the command line, thus removing
  927.                 the annoyance of having the command line becoming part
  928.                 of the drawing printed out.
  929.                 
  930.  
  931. Remarks         See previous pages for the color table used for the various
  932.                 graphics adapters. See also the notes on compatibility between
  933.                 adapters.
  934.  
  935. See Also        .backdrop
  936.  
  937. Bugs            There are never enough colors.  There is no orange. The
  938.                 backdrop color affects the way these colors are displayed,
  939.                 in ways you can best judge by experimentation.
  940.  
  941. Example         .color RED
  942.  
  943. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  944.  
  945.  
  946. .dot n1 n2
  947. ---- -- --
  948.  
  949.  
  950. Description    This command "sets" one pixel on the screen
  951.                 using the current color (defined by the .color command)
  952.                 at the viewport location x = n1, y = n2.
  953.  
  954. Remarks         Can be used to place random dots in your colors of
  955.                 choice on the screen.
  956.  
  957. See Also        .color, .backdrop
  958.  
  959.  
  960. Bugs            Not very efficient for setting large numbers of pixels.
  961.  
  962.  
  963. Example         .pixel 83  237
  964.  
  965. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  966.  
  967.  
  968.  
  969.  
  970. .ellipse n1 n2 n3 n4 n5 n6   (line ellipse)
  971. -------- -- -- -- -- -- --
  972.  
  973. .fellipse  n1 n2 n3 n4 n5 n6 (filled ellipse)
  974. ---------  -- -- -- -- -- --
  975.  
  976. Description    Used to draw a ellipse in the viewport. The center of the
  977.                 ellipse is at x = n5, y = n6 in viewport coordinates. This
  978.                 routine can be used to draw an ellipse which is rotated
  979.                 by some arbitrary angle of n3 degrees around its center point.
  980.  
  981.                 n1 = First axis length
  982.                 n2 = Aspect ratio relative to first axis. This is a floating
  983.                      point number from 0.0 to almost as large as you want.
  984.                 n3 = Inclination, in degrees, of the first axis from
  985.                      horizontal.
  986.                 n4 = step angle in degrees.  The algorithm used depends on 
  987.                      incrementing around the ellipse from 0 to 360 degrees 
  988.                      every n4 degrees. When n4 = 1 there is sufficient 
  989.                      detail that the ellipse looks smooth.  Increments 
  990.                      such as 5 or 10 degrees also usually look reasonable.
  991.                      However, increments such as 60 degrees can be used,
  992.                      which results in some interesting polygons.
  993.                 n5 = x axis location of center of ellipse in viewport
  994.                      coordinates.
  995.                 n6 = y axis location of center of ellipse in viewport
  996.                      coordinates.
  997.  
  998.  
  999. Remarks        Clipping at the edge of the viewport WILL occur for ellipses 
  1000.                 drawn to be larger than the viewport. This can be used to 
  1001.                 advantage (like say you want to draw an artificial horizon),
  1002.                 or for zooming into a drawing. See description of clipping
  1003.                 elsewhere.  Rotation of the ellipse is useful for generating
  1004.                 interesting effects.
  1005.  
  1006. See Also    .color, .circle
  1007.  
  1008. Defaults        First axis length n1 = 250, 
  1009.                 Aspect ratio n2 = 1.00
  1010.                 First axis inclination = 0 degrees,
  1011.                 Step angle = 5 degrees,
  1012.                 Center is 500, 320.
  1013.  
  1014. Bugs        Aliasing on the edges of the ellipse is NOT removed.
  1015.                 Very tiny ellipses will thus appear lumpy.
  1016.  
  1017. Example        .ellipse 200 .7 45 3 300 373
  1018.  
  1019. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1020.  
  1021.  
  1022.  
  1023. .init
  1024. -----
  1025.  
  1026.  
  1027. Description    This command is used to clear the screen of all text
  1028.                 and graphics.  The effect is nearly the same as the
  1029.                 DOS command CLS in DOS.
  1030.  
  1031.  
  1032. Remarks        
  1033.  
  1034. See Also    .backdrop
  1035.  
  1036. Bugs        
  1037.  
  1038. Example        .init
  1039.  
  1040.  
  1041. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1042.  
  1043.  
  1044.  
  1045.  
  1046. .line n1 n2 n3 n4
  1047. ----- -- -- -- --
  1048.  
  1049. Description    Used to draw a line from the first point to the second
  1050.                 point, in the current color.  The viewport coordinates of the
  1051.                 first point are x = n1, y = n2.  The viewport coordinates
  1052.                 of the second point are x = n3, y = n4.
  1053.  
  1054. Remarks        The endpoints can lie outside the viewport. Active clipping
  1055.                 will ensure that only the portion of the line inside the
  1056.                 viewport will be shown.
  1057.  
  1058. See Also    .polygon, .color
  1059.  
  1060. Bugs        Aliasing effects ("zaggies") are NOT eliminated by this
  1061.                 program.
  1062.  
  1063. Example        .line 23 49 800 300
  1064.  
  1065. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1066.  
  1067.  
  1068.  
  1069.  
  1070. .pitch n1
  1071. ------ --
  1072.  
  1073. Description    Used to define/redefine the default pitch frequency
  1074.                 for the tone generated by .beep.  The value n1 is a
  1075.                 decimal integer for a frequency in Hertz
  1076.  
  1077. Remarks        Low pitches are more tolerable with long beeps than
  1078.                 high pitches.
  1079.  
  1080. See Also    .beep
  1081.  
  1082. Bugs            Based on timer chip in your computer, and the clock
  1083.                 frequency of the timer chip.  The actual pitch may
  1084.                 end up different than expected if your computer's timer
  1085.                 runs very fast or very slow.
  1086.  
  1087. Example        .pitch 440
  1088.  
  1089. Another Example
  1090.                 .pitch 800
  1091.                 .beep 3
  1092.                 .beep 1    for the Morse code for "N"
  1093.  
  1094. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1095.  
  1096.  
  1097.  
  1098.  
  1099. .polygon   (open polygon)
  1100. -------- 
  1101. n1 n2 n3 n4 n5 n6 ...  .end
  1102. -- -- -- -- -- --      ----
  1103.  
  1104.  
  1105. .fpolygon (filled polygon)
  1106. -------- 
  1107. n1 n2 n3 n4 n5 n6 ...  .end
  1108. -- -- -- -- -- --      ----
  1109.  
  1110.  
  1111. Description    Polygon is used to draw    polygons. The end points of the
  1112.                 line segments of the polygon are determined by each
  1113.                 PAIR of coordinates, starting with (n1, n2).  The number
  1114.                 of points determining the polygon can range up to 512.
  1115.                 Polygons having only one point are "dots". Polygons
  1116.                 having two points only are lines. (Interesting!)
  1117.                 Three points determine a triangle, etc. However, the
  1118.                 most useful features of polygons are when they are
  1119.                 a) Irregular
  1120.                 b) Involuted
  1121.                 Such polygons can be used to draw almost any shape.
  1122.                 See the provided examples for use of polygons.
  1123.  
  1124.                 Polygons are drawn or filled with the default color
  1125.                 or the color from the last .color command.
  1126.  
  1127. Special Note:   Data points are entered continuously, line after line,
  1128.                 without regard for beginning a line with # or .  In fact,
  1129.                 the use of . or # should be avoided inside the data,
  1130.                 but white space is permitted.  The list is terminated with
  1131.                 one final entry, ".end" as below.
  1132.  
  1133. Remarks         The .ellipse and .star commands in fact use the same
  1134.                 display routines as polygon.
  1135.  
  1136. See Also    .end   The .end command is used to terminate the
  1137.                 list of points, after which the program counts up
  1138.                 the list of points and begins drawing.
  1139.  
  1140. Bugs            The standard C graphics library is used for polygon 
  1141.                 filling. There are some examples (especially stars 
  1142.                 with large numbers of points) where filled polygons 
  1143.                 have slight zaggies on the edges that are caused by 
  1144.                 the standard library routines.
  1145.  
  1146. Example        .fpolygon 
  1147.                 330 359 335 357 340 359 355 364 350 371 345 377 340 369
  1148.                 335 372 330 377 325 371 320 368 320 362 .end
  1149.  
  1150.                 draws the three towed foot of a bird.
  1151.                 
  1152.  
  1153. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1154.  
  1155.  
  1156.  
  1157. .require n1
  1158. -------- --
  1159.  
  1160.  
  1161. Description    This command MUST be the first line in the data file
  1162.                 IF it is used.  However, it does not necessarily have
  1163.                 to be used at all.
  1164.  
  1165.                 This command is used to warn the user that the data
  1166.                 that is going to come later is only compatible with
  1167.                 (requires) a certain type of graphics adapter, e.g.
  1168.                 it contains colors that only look right on a VGA.
  1169.  
  1170.                 The possible choices for n1 are:
  1171.                 VGA, OVGA, MCGA, EGA, OEGA, HGC, CGA, and OCGA.
  1172.  
  1173.                 The n1 values are NOT case sensitive, however.
  1174.  
  1175.                 When the "require" parameter (e.g. VGA) does not match
  1176.                 the adapter in the computer (e.g. HGC) the program
  1177.                 will prepare to terminate.
  1178.  
  1179. Remarks            This is merely a control feature to help unwary users
  1180.                 by warning them if the file is incompatible with the
  1181.                 graphics adapter in their computer.  It is usually 
  1182.                 used to help users of monochrome adapters who would 
  1183.                 otherwise run color graphics data through the program 
  1184.                 and receive an all white set of polygons and graphics 
  1185.                 that would be fairly unglorious.  It can also be used
  1186.                 to indicate that the aspect ratio may not be right.
  1187.                 E.g. graphics and text may become misaligned if run
  1188.                 through the wrong adapter.  The whole line can be removed
  1189.                 from the file, or commented out with #, in order to
  1190.                 remove its effect.
  1191.  
  1192. See Also    .aspect
  1193.  
  1194. Bugs        
  1195.  
  1196. Example        .require VGA
  1197.  
  1198.  
  1199. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1200.  
  1201.  
  1202.  
  1203.  
  1204.  
  1205. .star n1 n2 n3 n4 n5 (open star)
  1206. ----- -- -- -- -- --
  1207.  
  1208. .fstar n1 n2 n3 n4 n5 (filled star)
  1209. ------ -- -- -- -- --
  1210.  
  1211. Description    Used to draw a star-shaped polygon.  The coordinates
  1212.                 of the center of the star are n1, n2.  The radius of
  1213.                 the outer circle of points of the star is n3. The radius
  1214.                 of the points forming the notches is n4.  The number
  1215.                 of points of the star is n5.  The range of n5 runs from
  1216.                 3 to 512.
  1217.  
  1218. Remarks        The endpoints can lie outside the viewport. Active clipping
  1219.                 will ensure that only the portion of the line inside the
  1220.                 viewport will be shown.   A 512-pointed star is a lot
  1221.                 of points!
  1222.  
  1223. See Also    .polygon, .color
  1224.  
  1225. Defaults:       n1 = 500, n2 = 300, n3 = 250, n4 = 80, n5 = 5.
  1226.  
  1227. Bugs        Aliasing effects ("zaggies") are NOT eliminated by this
  1228.                 program. Especially, large filled stars with many points 
  1229.                 will have some strange effects due to the filled polygon
  1230.                 routine from the C library.
  1231.  
  1232. Example        .star 500 300 200 50 28
  1233.  
  1234. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1235.  
  1236.  
  1237.  
  1238.  
  1239. .text n1 n2 n3
  1240. ----- -- -- --
  1241.  
  1242.  
  1243. Description    This command is used to place text on the screen in the
  1244.                 middle of the graphics display.
  1245.  
  1246.                 n1 = row coordinates of text ( 1 to 22 ).
  1247.  
  1248.                 n2 = column coordinates of the first letter of the
  1249.                      text  ( 1 to 80 for all adapters except
  1250.                      CGA, and 1 to 40 for CGA adaptors).
  1251.  
  1252.                 n3 = any text in ASCII, even if containing more than
  1253.                      one word.  If you want this file to work with
  1254.                      CGA as well as others, and you are editing it
  1255.                      on something else besides CGA, try not to make
  1256.                      the length of the text on n3 longer than 40
  1257.                      characters.
  1258.  
  1259. Remarks         Alignment with graphics can be somewhat problematic.
  1260.                 These routines attempt to serve all graphics adapters.
  1261.                 CGA adapters, which have such large text characters,
  1262.                 will always be even more problematic.
  1263.  
  1264. See Also    .cgatext
  1265.  
  1266. Bugs        The C library used does not have the ability to
  1267.                 output generic BIOS character generator text in just
  1268.                 any location on the graphics screen.  BIOS characters
  1269.                 are forced to reside on text coordinates.  This is a major
  1270.                 problem, which until solved, makes alignment of text and
  1271.                 graphics problematic, especially when this program attempts
  1272.                 to work on all graphics adapters.  "Personal Engineering"
  1273.                 magazine recently discussed this issue.  Real graphics
  1274.                 fonts from the C compiler are available, but these require
  1275.                 payment of a royalty to BITSTREAM, which is not going to
  1276.                 be compatible with the idea here of free software.
  1277.  
  1278. Examples    .text 4 8 The quick brown fox jumped
  1279.  
  1280.                 .text 7 20 ~We the people
  1281.  
  1282. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1283.  
  1284.  
  1285.  
  1286.  
  1287.  
  1288. .trace n1
  1289. ------ --
  1290.  
  1291. Description    Trace is used to select whether or not to display the
  1292.                 entire array of parameters from a ".polygon" or ".wave"
  1293.                 command, or to skip the display beyond the first line.
  1294.                 If trace is on, each line of parameters is displayed
  1295.                 successively, as parsed, on line 23.  If trace is not
  1296.                 on, the parse is done "silently".
  1297.  
  1298.                 Parameter n1 is not case sensitive and can be either:
  1299.  
  1300.                 n1 = ON   or  n1 = OFF
  1301.  
  1302. Remarks        Trace is useful for finding "bad spots" in a parameter
  1303.                 list.
  1304.  
  1305. See Also    .polygon    and   .wave
  1306.  
  1307. Bugs        Unfortunately, if the file contains a long list of coordinate
  1308.                 parameters, turning on trace will consume more time while the
  1309.                 display routines print the text one line at a time on line 23.
  1310.                 
  1311. Example        .trace on
  1312.  
  1313.  
  1314. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1315.  
  1316.  
  1317.  
  1318.  
  1319. .wave
  1320. ----- 
  1321. n1 n2 n3 n4 n5 n6 ... .end
  1322. -- -- -- -- -- --     ----
  1323.  
  1324.  
  1325. Description    Wave is used to draw waveforms or a long set of contiguous
  1326.                 linked line segments. The end points of the line segments 
  1327.                 of the polygon are determined by each PAIR of coordinates,
  1328.                 starting with (n1, n2).  The number of points determining the 
  1329.                 waveform can range up to 512.  For drawing graphs or waveforms,
  1330.                 this routine does NOT perform curve fitting, smoothing,
  1331.                 or draw with Bezier or B-spline techniques. SPECIAL NOTE:
  1332.                 the y-azis coordinate system starts at the top of the screen, 
  1333.                 not the bottom. This should be taken into account when
  1334.                 other programs are used to calculate the set of points and this
  1335.                 program is used to graph the waveform, using .box, .fbox,
  1336.                 .text, and .wave.
  1337.  
  1338.                 Waves are drawn or filled with the default color
  1339.                 or the color from the last .color command.                
  1340.  
  1341. Special Note:   Data points are entered continuously, line after line,
  1342.                 without regard for beginning a line with # or .  In fact,
  1343.                 the use of . or # should be avoided inside the data,
  1344.                 but white space is permitted.  The list is terminated with
  1345.                 one final entry, ".end" as below.
  1346.  
  1347. Remarks         This is similar to the .polygon command.
  1348.  
  1349. See Also    .end   The .end command is used to terminate the
  1350.                 list of points, after which the program counts up
  1351.                 the list of points and begins drawing.
  1352.  
  1353. Bugs            This may not be the most comfortable way to actually
  1354.                 draw a graph of some data, since the y coordinate
  1355.                 starts at the top of the screen, not the bottom.
  1356.  
  1357. Example        .box 1 1 600 400
  1358.                 .wave 1 200 100 160 200 230 300 180 400 330
  1359.                 500 200 599 400 .end
  1360.  
  1361.  
  1362. GIL COMMAND REFERENCE                   Copyright (c)  1991  Glenn L. Williams 
  1363.  
  1364.  
  1365.  
  1366.    Possible future commands:
  1367.  
  1368.    Commands that make thick lines. But such commands need to execute very
  1369.    quickly!  The only way to make thick lines right now is to draw them
  1370.    by laying down parallel lines.
  1371.  
  1372.    Commands to draw "waveforms" and "zig-zags" with cubic spline, Bezier
  1373.    spline, or B-spline methods.  "Splines" are methods similar to  drawing
  1374.    with a "french curve" on paper.
  1375.  
  1376.    Better graphics text characters.  "Personal Engineering" magazine
  1377.    recently discussed this issue.
  1378.